package cn.wjh.business.domain;

import cn.wjh.common.annotation.Excel;
import cn.wjh.common.core.domain.BaseEntity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;
import java.util.List;

/**
 * 翻译对象 tbl_translate
 *
 * @author jiraWu
 * @date 2023-11-30
 */
@EqualsAndHashCode(callSuper = true)
@Data
@TableName("tbl_translate")
public class Translate extends BaseEntity {
    private static final long serialVersionUID = 1L;


    /**
     * 翻译Id
     */
    @TableId
    private Long translateId;


    /**
     * 产品Id
     */
    @Excel(name = "产品Id")
    private Long productId;

    /**
     * 用户Id
     */
    @Excel(name = "用户Id")
    private Long userId;

    /**
     * 父级Id
     */
    @Excel(name = "父级Id")
    private Long parentId;

    /**
     * 翻译历史Id
     */
    private Long translateHistoryId;

    /**
     * 加密字符串
     */
    @Excel(name = "加密字符串")
    private String stringKey;


    /**
     * 语种编码
     */
    @Excel(name = "语种编码")
    private String languageCode;


    /**
     * 值
     */
    @Excel(name = "值")
    private String translateVal;


    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createTime;


    /**
     * 创建人
     */
    private String createBy;


    /**
     * 修改时间
     */
    private Date updateTime;


    /**
     * 修改人
     */
    private String updateBy;


    /**
     * 是否删除 0否 1是
     */
//    @TableLogic(value = "0", delval = "1")
    private Boolean delFlag;


    /**
     * 产品
     */
    @TableField(exist = false)
    private Product product;

    /**
     * 语言
     */
    @TableField(exist = false)
    private Language language;


    /**
     * 子级翻译版本
     */
    @TableField(exist = false)
    private List<Translate> children;
}

